//==========================================================================
// Copyright (c) 2000-2008,  Elastos, Inc.  All Rights Reserved.
//==========================================================================

#include <asm.h>

.extern C_SYMBOL(BspStartup)
.global C_SYMBOL(mainCRTStartup)

.section CODEINIT
C_SYMBOL(mainCRTStartup):
    cld

    xor     %ebp, %ebp        // clear frame pointer

    pushl   %ebx              // parameter: MultiBootInfo pointer
    pushl   %eax              // parameter: mulitiboot magic number

    // although absolute function addresses are unusable during startup,
    // the relative addresses work. 'call' use the latter.
    //
    call    C_SYMBOL(BspStartup)

